package com.yyt.springbootdemorabbitmq.receiver;

import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @author: yeyangtao
 * @date: 2019/12/3 15:14
 */
@Component
@RabbitListener(queues = "string")
public class StringReceiver {

    @RabbitHandler
    public void process(String hello) {
        System.out.println("接收string消息：" + hello);
    }
}
